

class Node implements Comparable{
		int weapons;
		int shots;
		// If we represent each weapon as a bit in an integer, we will have to store a maximum of 32,768 values (2^15, as there is a maximum of 15 weapons
		public Node(int weapons, int shots){
			this.weapons = weapons;
			this.shots = shots;
		}
		
		public int getWeapons(){
			return this.weapons;
		}
		public int getShots(){
			return this.shots;
		}
		// Define a comparator that puts nodes with less shots on top appropriate to your language
		@Override
		public int compareTo(Object o) {
			if (!(o instanceof Node)){
				throw new ClassCastException("Invalid object");
			}
			
			int shots = ((Node)o).getShots();
			if (this.getShots() < shots) return -1;
			else if (this.getShots() > shots) return 1;
			else 
				return 0;
		}
	}